function loadPrint(obj,data,where,isprint,munber,checai){
	//提出在派工取消的时候派工数等于取消数加上已取消数时的数据
	var ar= new Array();
	if(where=='prodetail'){//生产派工取消
		for(var i=0;i<data.length;i++){
			if(data[i].zd013Quantity==undefined||isNaN(data[i].zd013Quantity)){
				data[i].zd013Quantity=0;
			}
			if(isNaN(data[i].zd019ReturnQuantity)){
				data[i].zd019ReturnQuantity=0;
			}
			if(isNaN(data[i].zdTheQuantity)){
				data[i].zdTheQuantity=0;		
			}
			if((data[i].zd013Quantity-data[i].zdTheQuantity-data[i].zd019ReturnQuantity)>0){
				ar.push(data[i]);
			}
		}
		data=ar;
	}
	var param= new Array();
	if(where == "otherIn"||where=="otherOut"||where == "prostoragein"||where == "purchaseware"
		||where == 'materialout'){
		if(where == "otherIn"){
			for(var i = 0 ; i <data.length ; i++){
				param.push(data[i].zd002MaterialsCode);
			}
		}
		if(where=="otherOut"){
			for(var i = 0 ; i <data.length ; i++){
				param.push(data[i].zd002MaterialsCode);
			}
		}
		if(where == "prostoragein"){
			for(var i = 0 ; i <data.length ; i++){
				param.push(data[i].zd002MaterialsCode);
			}
		}
		if(where == 'materialout'){
			for(var i = 0 ; i <data.length ; i++){
				param.push(data[i].zd002MaterialsCode);
			}
		}
		if(where == "purchaseware"){
			for(var i = 0 ; i <data.length ; i++){
				param.push(data[i].zd004Code);
			}
		}
		if(param.length>0){
			$.ajax({
				url : ctx+"/excel/getMaterialSerise.do",
				dataTpye: "text",
				type: "post",
				async:false,
				data:{"codes":param.toString()},
				success: function(dt){
					var obj=JSON.parse(dt); 
					for(var i = 0 ; i <data.length ; i++){
						data[i].id=obj[param[i]];//id用于临时存储系列
					}
				}	
			});
		}
	}
	var arr=new Array();
	arr.push(obj);
	arr.push(data);
	if(data.length==0){
		alert("没有要打印的物料，请保存之后再打印");
		return false;
	}
	try {
		LODOP;
	} catch (e) {
		LODOP=getLodop();
	}
	LODOP.SET_PRINT_MODE('NOCLEAR_AFTER_PRINT',false);//设置打印或预览后内容不清空是否为真
	// 设置打印机 SET_PRINTER_INDEX(oIndexOrName) 
	for(var j=0;j<arr.length;j=j+2){
		var rs=new Array();
		var now=1;
		for(var i=1;i<=arr[j+1].length;i++){
			rs.push(arr[j+1][i-1]);
			if(where !='prodetail'&&where !='prodispat'&&where !='batchIn' && where!='checkBack'){
				if((i%9==0&&i!=1)||i==arr[j+1].length){
					LODOP.NEWPAGE();
					var total=0;
					if(data.length%9==0&&data.length!=0){
						total=data.length/9;
					}else{
						total=Math.floor(data.length/9)+1;
						
					}
					if(where == "otherIn"){//其他入库 
						otherIn(arr[j],rs,isprint,materialtable(),total,now);
					}else if(where=="otherOut"){//其他出库编辑
						otherOut(arr[j],rs,isprint,materialtable(),total,now);
					}else if(where == "prostoragein"){//生产成品入库
						prostoragein(arr[j],rs,isprint,productiontable(),total,now);
					}else if(where == "purchaseware"){//采购入库
						purchaseware(arr[j],rs,isprint,materialtable(),total,now);
					}else if(where == 'allocation'){//调拨
						allocation(arr[j],rs,isprint,diaobo());
					}else if(where == 'prostorageout'){//销售出库
						prostorageout(arr[j],rs,isprint,productiontable(),total,now);
					}else if(where == 'materialout'){//
						material(arr[j],rs,isprint,materialtable(),total,now);
					} else if(where == 'cbotherout'){ //其他出库 反审
						cbotherout(arr[j],rs,isprint,fsqitachuku());
					}
					now++;
					rs=new Array();
				}
			}else if(where =='prodispat'){//生产派工
				if(((i%7==0&&i!=1)||i==arr[j+1].length)){
					LODOP.NEWPAGE();
					var total=0;
					if(data.length%7==0&&data.length!=0){
						total=data.length/7;
					}else{
						total=Math.floor(data.length/7)+1;
						
					}
					var table="";
					if(checai){
						table=paigongcc();
					}else{
						table=paigong();
					}
					prodetail(arr[j],rs,isprint,table,total,now,where,munber,checai);
				
					now++;
					rs=new Array();
				}
			}else if(where =='prodetail'){//生产派工取消
				if(((i%7==0&&i!=1)||i==arr[j+1].length)){
					LODOP.NEWPAGE();
					var total=0;
					if(data.length%7==0&&data.length!=0){
						total=data.length/7;
					}else{
						total=Math.floor(data.length/7)+1;
						
					}
					var table="";
					if(checai){
						table=paigongcc();
					}else{
						table=paigong();
					}
					prodetail(arr[j],rs,isprint,table,total,now,where,munber,checai);
					now++;
					rs=new Array();
				}
			}else if(where == 'checkBack'){
				if(((i%7==0&&i!=1)||i==arr[j+1].length)){
					LODOP.NEWPAGE();
					var table=checkBackTable();
					checkBackAll(arr[j],rs,isprint,table);
				}
			}else if(where == "batchIn"){
				if(((i%9==0&&i!=1)||i==arr[j+1].length)){
					LODOP.NEWPAGE();
					var total=0;
					if(data.length%7==0&&data.length!=0){
						total=data.length/9;
					}else{
						total=Math.floor(data.length/9)+1;
						
					}
					batchIn(arr[j],rs,isprint,materialtable(),total,now);
					now++;
					rs=new Array();
				}
				
			}
		}
	}
	
}
//成品出库
function production(obj,data,isprint,table,total,now){
	var hight=30;
	LODOP.PRINT_INITA(0,0,824,600,"成品出库");
	LODOP.ADD_PRINT_TABLE(140,1,"202.99mm","115.89mm",table);
	LODOP.ADD_PRINT_LINE(33,726,8,752,0,1);
	LODOP.ADD_PRINT_TEXT(23,737,25,20,total);
	LODOP.ADD_PRINT_TEXT(9,726,25,20,now);
	LODOP.ADD_PRINT_TEXT(14,211,354,35,"佛山市高尔顿家具有限公司");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",20);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,327,110,30,"成品出库单");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",16);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,570,45,25,"单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,607,160,25,"单据编号");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,5,65,25,"PI单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,66,135,25,"12345678");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,5,55,25,"仓库:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,53,105,25,"成品仓");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,306,55,25,"客户:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,349,165,25,"印度——三");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,305,65,25,"业务员:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,363,140,25,"张三");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,570,60,25,"日期:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,617,150,25,"2015年01月25日");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	for(var i=0;i<data.length;i++){
		LODOP.ADD_PRINT_TEXT(174+i*hight,2,65,30,"套床");//系列
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+i*hight,67,165,30,"我是中国人，布料最多五个字");//名称
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+i*hight,230,185,30,"G888");//型号
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+i*hight,412,125,30,"规格");//规格
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+i*hight,534,45,30,"单位");//单位
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+i*hight,579,65,30,"999.99");//数量
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+i*hight,641,125,30,"这批货是阿三的货");//描述
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	}
	LODOP.ADD_PRINT_TEXT(447,4,60,25,"制单人:");
	LODOP.ADD_PRINT_TEXT(447,62,115,25,"张三");
	LODOP.ADD_PRINT_TEXT(447,194,60,25,"领料人：");
	LODOP.ADD_PRINT_TEXT(447,253,110,25,"李四");
	LODOP.ADD_PRINT_TEXT(447,383,70,25,"仓库主管：");
	LODOP.ADD_PRINT_TEXT(447,453,100,25,"王五");
	LODOP.ADD_PRINT_TEXT(448,588,50,25,"合计：");
	LODOP.ADD_PRINT_TEXT(448,638,100,25,"88888888888");
	LODOP.ADD_PRINT_TEXT(474,3,85,25,"一 财务(黄):");
	LODOP.ADD_PRINT_TEXT(474,307,85,25,"二 仓库(白):");
	LODOP.ADD_PRINT_TEXT(474,573,85,25,"三 车间(红):");
	print(isprint,table);
}
//多pi
function batchIn(obj,data,isprint,table,total,now){
	var left=0; var hight=30;
	LODOP.PRINT_INITA(0,0+left,824,600,"多PI录入");
	LODOP.ADD_PRINT_TABLE(140,2,"202.99mm","115.89mm",table);
	LODOP.ADD_PRINT_LINE(33,726,8,752,0,1);
	LODOP.ADD_PRINT_TEXT(23,737,25,20,total);
	LODOP.ADD_PRINT_TEXT(9,726,25,20,now);
	LODOP.ADD_PRINT_TEXT(14,211,354,35,"佛山市高尔顿家具有限公司");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",20);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,320,125,30,"多PI入库单");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",16);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,561,45,25,"单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,598,160,25,obj.zd001Code);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,5,65,25,"供应商:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,66,135,25,obj.zd007SupplierName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,563,55,25,"仓库:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,611,105,25,obj.zd003WhName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,306,75,25,"送货单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(85,377,155,25,obj.zd002InNumber);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,306,70,25,"业务员:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,373,140,25,"");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(58,6,60,25,"日期:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	var date = obj.zd004InDate.split('-');
	LODOP.ADD_PRINT_TEXT(58,53,150,25,date[0]+"年"+date[1]+"月"+date[2]+"日");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	var money=0;
	for(var i=0;i<data.length;i++){
		LODOP.ADD_PRINT_TEXT(174+hight*i,2,85,30,data[i].zd005PiCode);//pi单号
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,87,40,30,data[i].zd011Series);//系列 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,127,135,30,data[i].zd002MaterName);//名称
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,261,125,30,data[i].zd002MaterModel);//型号 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,385,90,30,data[i].zd002MaterSpec);//规格
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,475,40,30,data[i].zd006Uint);//单位 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		var inq=parseFloat(data[i].zd003InQuantity);
		var back=0;
		if(!isNaN(data[i].zd003BackInQuantity)){
			back=parseFloat(data[i].zd003BackInQuantity);
    		}
		inq=inq-back;
		LODOP.ADD_PRINT_TEXT(174+hight*i,515,40,30,inq);//数量 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,555,55,30,data[i].zd007Price);//单价 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,606,64,30,data[i].zd008AllMoney);//合计
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		if(!(data[i].zd008AllMoney==""||data[i].zd008AllMoney==null||isNaN(data[i].zd008AllMoney))){
			money=money+parseFloat(data[i].zd008AllMoney);
		}
		LODOP.ADD_PRINT_TEXT(176+hight*i,668,100,26,data[i].zd009Describtion);//描述
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	}
	LODOP.ADD_PRINT_TEXT(447,4,60,25,"制单人:");
	LODOP.ADD_PRINT_TEXT(447,62,115,25,obj.username);
	LODOP.ADD_PRINT_TEXT(447,194,60,25,"送货人：");
	LODOP.ADD_PRINT_TEXT(447,253,110,25,"");
	LODOP.ADD_PRINT_TEXT(447,383,70,25,"收货人：");
	LODOP.ADD_PRINT_TEXT(447,453,100,25,"");
	LODOP.ADD_PRINT_TEXT(448,588,50,25,"合计：");
	LODOP.ADD_PRINT_TEXT(448,638,100,25,money);
	LODOP.ADD_PRINT_TEXT(474,3,85,25,"一 财务(黄):");
	LODOP.ADD_PRINT_TEXT(474,307,85,25,"二 仓库(白):");
	LODOP.ADD_PRINT_TEXT(474,580,100,25,"三 供应商(红):");
	LODOP.ADD_PRINT_TEXT(117,5,45,25,"客户:");
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,51,125,25,"");
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(119,563,40,25,"备注:");
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(119,602,165,25,obj.zd009Remark);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	print(isprint,table);
}

//反审打印
function checkBackAll(obj,data,isprint,table){
	var left=-9;
	var top=150;
	LODOP.PRINT_INIT("单据反审");
	LODOP.ADD_PRINT_TABLE(112,2,786,333,table);
	LODOP.ADD_PRINT_TEXT(11,231+left,328,30,"佛山市高尔顿家具有限公司");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",19);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(44,323+left,100,25,"反审单");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",17);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(53,11+left,65,20,"反审单号:");
	LODOP.ADD_PRINT_TEXT(53,78+left,150,20,obj.zd001Code);
	LODOP.ADD_PRINT_TEXT(74,10+left,95,20,"入库/出库单号:");
	LODOP.ADD_PRINT_TEXT(74,103+left,125,20,obj.zd005OriCode);
	LODOP.ADD_PRINT_TEXT(93,279,65,20,"仓库名称:");
	LODOP.ADD_PRINT_TEXT(93,342,100,20,"cangkuming");
	LODOP.ADD_PRINT_TEXT(94,11+left,51,20,"PI单号:");
	LODOP.ADD_PRINT_TEXT(93,61+left,170,20,"pidanhao");
	LODOP.ADD_PRINT_TEXT(53,535,55,20,"供应商:");
	LODOP.ADD_PRINT_TEXT(53,590,150,20,"gongyingshang");
	LODOP.ADD_PRINT_TEXT(73,535,65,20,"反审日期:");
	LODOP.ADD_PRINT_TEXT(73,600,140,20,"fanshenriqi");
	LODOP.ADD_PRINT_TEXT(92,535,75,20,"出入库日期:");
	LODOP.ADD_PRINT_TEXT(93,610,130,20,"churushijian");
	for(var i=0;i<7;i++){
		LODOP.ADD_PRINT_TEXT(top+i*28.7,11+left,125,20,data[i].zd002MaterName);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(top+i*28.7,135+left,125,20,data[i].zd002MaterModel);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(top+i*28.7,260+left,120,20,data[i].zd002MaterSpec);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(top+i*28.7,379+left,105,20,data[i].zd002MaterColor);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(top+i*28.7,486+left,100,20,data[i].zd002MaterQuanlity);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(top+i*28.7,586+left,44,20,data[i].zd003MaterUnit);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(top+i*28.7,629+left,55,20,data[i].zd007SgQuantity);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(top+i*28.7,683+left,70,20,data[i].zd010TheBackQuantity);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	}
	LODOP.ADD_PRINT_TEXT(346,575,69,20,"制单人：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(346,640,100,20,"张三");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	print(isprint,table);
}


//生产派工 派工取消
function prodetail(obj , data , isprint , table , total , now , where , munber , checai ){
	LODOP.SET_PRINT_PAGESIZE (2, 0, 0,"A5");//设置为横向打印  纵向 宽 高 纸张（宽高 和纸张选一个）
	LODOP.PRINT_INITA(0,0,808,796,"派工");
	LODOP.ADD_PRINT_TABLE("31.01mm",0,603,224,table);
	LODOP.ADD_PRINT_TABLE("136.02mm",0,599,220,table);
	LODOP.ADD_PRINT_TEXT(18,165,231,20,"生产派工单");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",20);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.ADD_PRINT_TEXT(403,165,236,20,"生产派工单");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",20);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	
	LODOP.ADD_PRINT_TEXT(61,6,50,20,"客户:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(459,6,55,20,"客户：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(61,58,205,20,obj.zd004CustomerName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(459,58,195,20,obj.zd004CustomerName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(61,348,55,20,"日期：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(459,346,55,20,"日期：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(61,402,140,20,obj.bizCreatorDate);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(459,402,141,20,obj.bizCreatorDate);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	
	LODOP.ADD_PRINT_TEXT(93,6,60,20,"领工人：");
	LODOP.ADD_PRINT_TEXT(490,6,60,20,"领工人：");
	
	if(where=='prodetail'){//生产派工取消
		LODOP.ADD_PRINT_TEXT(93,65,75,20,data[0].zd008UseName);
		LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
		LODOP.ADD_PRINT_TEXT(490,65,75,20,data[0].zd008UseName);
		LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	}else if(where=='prodispat'){//生产派工
		LODOP.ADD_PRINT_TEXT(93,65,75,20,data[0].zdUserName);
		LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
		LODOP.ADD_PRINT_TEXT(490,65,75,20,data[0].zdUserName);
		LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	
	}
	

	LODOP.ADD_PRINT_TEXT(93,142,70,20,"业务员：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(490,142,70,20,"业务员：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(93,205,65,20,obj.zd007SalesMan);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(490,205,60,20,obj.zd007SalesMan);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	
	LODOP.ADD_PRINT_TEXT(93,345,70,20,"PI编号：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(489,345,70,20,"PI编号：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(93,412,150,20,obj.zd003PiCode);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(489,412,145,20,obj.zd003PiCode);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	
	if(where=='prodetail'){//生产派工取消
		LODOP.ADD_PRINT_TEXT(37,349,70,20,"料单号:");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
		LODOP.ADD_PRINT_TEXT(436,344,70,20,"料单号:");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
		LODOP.ADD_PRINT_TEXT(38,410,130,20,obj.zd001FormCode);
		LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
		LODOP.ADD_PRINT_TEXT(437,410,130,20,obj.zd001FormCode);
		LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	}else if(where=='prodispat'){//生产派工
		LODOP.ADD_PRINT_TEXT(37,350,65,20,"料单号:");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
		LODOP.ADD_PRINT_TEXT(436,350,70,20,"料单号:");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
		LODOP.ADD_PRINT_TEXT(38,410,130,20,munber);
		LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
		LODOP.ADD_PRINT_TEXT(437,410,130,20,munber);
		LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	
	}
	LODOP.ADD_PRINT_LINE(27,502,7,522,0,1);
	LODOP.ADD_PRINT_LINE(427,502,407,522,0,1);
	LODOP.ADD_PRINT_TEXT(18,510,30,20,total);
	LODOP.ADD_PRINT_TEXT(418,510,30,20,total);
	LODOP.ADD_PRINT_TEXT(7,503,23,20,now);
	LODOP.ADD_PRINT_TEXT(407,503,23,20,now);
	var money=0;
	var down=26.45;
	if(!checai){//是否是车裁车间
		for(var i=0; i<data.length;i++){
			LODOP.ADD_PRINT_TEXT(152+down*i,2,70,20,data[i].zd006MaterialsName);//产品名称
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(549+down*i,2,70,20,data[i].zd006MaterialsName);
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			
			
			LODOP.ADD_PRINT_TEXT(152+down*i,72,130,20,data[i].zd010MaterialsModel);//型号
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(549+down*i,72,130,20,data[i].zd010MaterialsModel);
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			
			LODOP.ADD_PRINT_TEXT(152+down*i,202,80,20,data[i].zd023MaterialsSize);//尺寸
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(549+down*i,202,80,20,data[i].zd023MaterialsSize);
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			
			LODOP.ADD_PRINT_TEXT(152+down*i,272,80,20,data[i].zd029ProcessName);//工序
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(549+down*i,272,80,20,data[i].zd029ProcessName);
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			if(where=='prodetail'){//生产派工取消
				if(data[i].zdTheQuantity==null||data[i].zdTheQuantity==undefined||isNaN(data[i].zdTheQuantity)){
					data[i].zdTheQuantity=0;
				}
				if(data[i].zd019ReturnQuantity==null||data[i].zd019ReturnQuantity==undefined||isNaN(data[i].zd019ReturnQuantity)){
					data[i].zd019ReturnQuantity=0;
				}
				//数量=派工数量zd013Quantity-取消数量zdTheQuantity-已取消数量zd019ReturnQuantity
				var mun=data[i].zd013Quantity-data[i].zdTheQuantity-data[i].zd019ReturnQuantity;
				LODOP.ADD_PRINT_TEXT(152+down*i,350,40,20,mun);//数量
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				LODOP.ADD_PRINT_TEXT(549+down*i,350,40,20,mun);
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				if(data[i].zd014Price==0||data[i].zd014Price==null||data[i].zd014Price==undefined){
					data[i].zd014Price=0;
				}
				LODOP.ADD_PRINT_TEXT(152+down*i,392,40,20,data[i].zd014Price.toFixed(2));//单价
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				LODOP.ADD_PRINT_TEXT(549+down*i,392,40,20,data[i].zd014Price.toFixed(2));
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				money=mun*parseFloat(data[i].zd014Price)+money;//注意数量
			}else if(where=='prodispat'){//生产派工
				//数量=派工数量
				LODOP.ADD_PRINT_TEXT(152+down*i,350,40,20,data[i].zdTheQuantity);//派工数量（实际派工数量）
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				LODOP.ADD_PRINT_TEXT(549+down*i,350,40,20,data[i].zdTheQuantity);
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				if(data[i].zd013Price==0||data[i].zd013Price==null||data[i].zd013Price==undefined){
					data[i].zd013Price=0;
				}
				LODOP.ADD_PRINT_TEXT(152+down*i,392,40,20,data[i].zd013Price.toFixed(2));//单价
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				LODOP.ADD_PRINT_TEXT(549+down*i,392,40,20,data[i].zd013Price.toFixed(2));
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				money=data[i].zdTheQuantity*parseFloat(data[i].zd013Price)+money;//注意数量
			}
			LODOP.ADD_PRINT_TEXT(152+down*i-5,432,100,20,data[i].zd021MaterialsDescription);
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(549+down*i-5,432,100,20,data[i].zd021MaterialsDescription);
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		}
	}else{
		for(var i=0; i<data.length;i++){
			LODOP.ADD_PRINT_TEXT(152+down*i,2,70,20,data[i].zd006MaterialsName);//产品名称
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(549+down*i,2,70,20,data[i].zd006MaterialsName);
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			
			
			LODOP.ADD_PRINT_TEXT(152+down*i,72,40,20,data[i].zd010MaterialsModel);//型号
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(549+down*i,72,40,20,data[i].zd010MaterialsModel);
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			
			LODOP.ADD_PRINT_TEXT(152+down*i,115,65,20,data[i].zd023MaterialsSize);//尺寸
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(549+down*i,115,65,20,data[i].zd023MaterialsSize);
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			
			LODOP.ADD_PRINT_TEXT(152+down*i,180,40,20,data[i].zd029ProcessName);//工序
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(549+down*i,180,40,20,data[i].zd029ProcessName);
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			if(where=='prodetail'){//生产派工取消
				if(data[i].zdTheQuantity==null||data[i].zdTheQuantity==undefined||isNaN(data[i].zdTheQuantity)){
					data[i].zdTheQuantity=0;
				}
				if(data[i].zd019ReturnQuantity==null||data[i].zd019ReturnQuantity==undefined||isNaN(data[i].zd019ReturnQuantity)){
					data[i].zd019ReturnQuantity=0;
				}
				//数量=派工数量zd013Quantity-取消数量zdTheQuantity-已取消数量zd019ReturnQuantity
				var mun=data[i].zd013Quantity-data[i].zdTheQuantity-data[i].zd019ReturnQuantity;
				LODOP.ADD_PRINT_TEXT(152+down*i,220,40,20,mun);//数量
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				LODOP.ADD_PRINT_TEXT(549+down*i,220,40,20,mun);
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				if(data[i].zd014Price==0||data[i].zd014Price==null||data[i].zd014Price==undefined){
					data[i].zd014Price=0;
				}
				LODOP.ADD_PRINT_TEXT(152+down*i,260,40,20,data[i].zd014Price.toFixed(2));//单价
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				LODOP.ADD_PRINT_TEXT(549+down*i,260,40,20,data[i].zd014Price.toFixed(2));
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				money=mun*parseFloat(data[i].zd014Price)+money;//注意数量
			}else if(where=='prodispat'){//生产派工
				//数量=派工数量
				LODOP.ADD_PRINT_TEXT(152+down*i,220,40,20,data[i].zdTheQuantity);//派工数量（实际派工数量）
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				LODOP.ADD_PRINT_TEXT(549+down*i,220,40,20,data[i].zdTheQuantity);
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				if(data[i].zd013Price==0||data[i].zd013Price==null||data[i].zd013Price==undefined){
					data[i].zd013Price=0;
				}
				LODOP.ADD_PRINT_TEXT(152+down*i,260,40,20,data[i].zd013Price.toFixed(2));//单价
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				LODOP.ADD_PRINT_TEXT(549+down*i,260,40,20,data[i].zd013Price.toFixed(2));
				LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
				money=data[i].zdTheQuantity*parseFloat(data[i].zd013Price)+money;//注意数量
			}
			LODOP.ADD_PRINT_TEXT(152+down*i-5,300,240,20,data[i].zd021MaterialsDescription);
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.SET_PRINT_STYLEA(0,"FontSize",9);
			LODOP.ADD_PRINT_TEXT(549+down*i-5,300,240,20,data[i].zd021MaterialsDescription);
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.SET_PRINT_STYLEA(0,"FontSize",9);
		}
	}
	LODOP.ADD_PRINT_TEXT(331,0,50,20,"主管:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(728,0,55,20,"主管：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(331,64,70,20,"");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(728,58,80,20,"");
	
	LODOP.ADD_PRINT_TEXT(331,120,70,20,"制单人：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(728,120,70,20,"制单人：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(331,180,70,20,obj.zhuguan);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(729,180,70,20,obj.zhuguan);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	
	LODOP.ADD_PRINT_TEXT(331,250,100,20,"领工人签字：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(729,250,100,20,"领工人签字：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	
	LODOP.ADD_PRINT_TEXT(331,400,50,20,"合计：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(729,400,50,20,"合计：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(331,450,60,20,money.toFixed(2));
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(729,450,60,20,money.toFixed(2));
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	print(isprint,table);
	
}
//领料出库
function material(obj,data,isprint,table,total,now){
	var left=0; var hight=30;
	LODOP.PRINT_INITA(0,0+left,824,600,"领料出库");
	LODOP.ADD_PRINT_TABLE(140,2,"202.99mm","115.89mm",table);
	LODOP.ADD_PRINT_LINE(33,726,8,752,0,1);
	LODOP.ADD_PRINT_TEXT(23,737,25,20,total);
	LODOP.ADD_PRINT_TEXT(9,726,25,20,now);
	LODOP.ADD_PRINT_TEXT(14,211,354,35,"佛山市高尔顿家具有限公司");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",20);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,320,125,30,"领料出库");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",16);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,561,45,25,"单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,598,160,25,obj.zd001MaterialCode);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,5,65,25,"供应商:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,66,135,25,"");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,563,55,25,"仓库:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,611,105,25,obj.zd011WhName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,306,75,25,"流水号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(85,377,155,25,obj.zd012RunningNumber);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,306,70,25,"业务员:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,373,140,25,"");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(58,6,60,25,"日期:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	var date = obj.zd010OtherDate.split('-');
	LODOP.ADD_PRINT_TEXT(58,53,150,25,date[0]+"年"+date[1]+"年"+date[2]+"日");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,5,45,25,"客户:");
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,51,125,25,"");
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(119,563,40,25,"备注:");
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(119,602,165,25,obj.zd007Remark);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	var allmony=0;
	for(var i=0;i<data.length;i++){
		LODOP.ADD_PRINT_TEXT(174+hight*i,2,85,30,obj.zd004PICode);//pi单号
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,87,40,30,data[i].id);//系列 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,127,135,30,data[i].zd002MaterialsName);//名称
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,261,125,30,data[i].zd004MaterialsModel);//型号 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,385,90,30,data[i].zd017MaterialsSize);//规格
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,475,40,30,data[i].zd006Unit);//单位 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		var out=parseFloat(data[i].zd007Quantity);
		LODOP.ADD_PRINT_TEXT(174+hight*i,515,40,30,out);//数量 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		var outm=parseFloat(data[i].zd009Price)*out;
		allmony=allmony+outm;
		LODOP.ADD_PRINT_TEXT(174+hight*i,555,55,30,data[i].zd009Price);//单价 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,606,64,30,outm);//合计
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(176+hight*i,668,100,26,data[i].zd009Describtion);//描述
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	}
	LODOP.ADD_PRINT_TEXT(447,4,60,25,"制单人:");
	LODOP.ADD_PRINT_TEXT(447,62,115,25,obj.zd006Aegnt);
	LODOP.ADD_PRINT_TEXT(447,194,60,25,"送货人：");
	LODOP.ADD_PRINT_TEXT(447,253,110,25,"");
	LODOP.ADD_PRINT_TEXT(447,383,70,25,"收货人：");
	LODOP.ADD_PRINT_TEXT(447,453,100,25,"");
	LODOP.ADD_PRINT_TEXT(448,588,50,25,"合计：");
	LODOP.ADD_PRINT_TEXT(448,638,100,25,allmony);
	LODOP.ADD_PRINT_TEXT(474,3,85,25,"一 财务(红):");
	LODOP.ADD_PRINT_TEXT(474,307,85,25,"二 仓库(白):");
	print(isprint,table);
}

//销售出库
function prostorageout(obj,data,isprint,table,total,now){
	var hight=30;
	LODOP.PRINT_INITA(0,0,824,600,"成品出库库单");
	LODOP.ADD_PRINT_TABLE(140,1,"202.99mm","115.89mm",table);
	LODOP.ADD_PRINT_LINE(33,726,8,752,0,1);
	LODOP.ADD_PRINT_TEXT(23,737,25,20,total);
	LODOP.ADD_PRINT_TEXT(9,726,25,20,now);
	LODOP.ADD_PRINT_TEXT(14,211,354,35,"佛山市高尔顿家具有限公司");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",20);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,300,140,30,"成品出库单");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",16);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,570,45,25,"单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,607,160,25,obj.zd001OutCode);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,5,65,25,"PI单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,66,135,25,obj.zd003PiCode);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,5,55,25,"仓库:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,53,105,25,obj.zd004WhName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,306,55,25,"客户:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,349,165,25,obj.zd012CustomerName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,305,65,25,"业务员:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,363,140,25,obj.zd015SalesMan);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	var date=obj.zd010OtherDate.split("-");
	LODOP.ADD_PRINT_TEXT(117,570,60,25,"日期:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,617,150,25,date[0]+"年"+date[1]+"月"+date[2]+"日");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	for(var i=0;i<data.length;i++){
		LODOP.ADD_PRINT_TEXT(174+hight*i,2,65,30,data[i].zd025Series);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,67,165,30,data[i].zd002MaterialsName);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,230,185,30,data[i].zd004MaterialsModel);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,412,125,30,data[i].zd016MaterialsSize);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,534,45,30,data[i].zd006Unit);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		var out=parseFloat(data[i].zd007Quantity);
		LODOP.ADD_PRINT_TEXT(174+hight*i,579,65,30,out);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,641,125,30,data[i].zd015MaterialsDescription);
	}
	LODOP.ADD_PRINT_TEXT(447,4,60,25,"制单人:");
	LODOP.ADD_PRINT_TEXT(447,62,115,25,obj.zd006Aegnt);
	LODOP.ADD_PRINT_TEXT(447,194,60,25,"领料人：");
	LODOP.ADD_PRINT_TEXT(447,253,110,25,"");
	LODOP.ADD_PRINT_TEXT(447,383,70,25,"仓库主管：");
	LODOP.ADD_PRINT_TEXT(447,453,100,25,"");
	LODOP.ADD_PRINT_TEXT(448,588,50,25,"合计：");
	LODOP.ADD_PRINT_TEXT(448,638,100,25,"");
	LODOP.ADD_PRINT_TEXT(474,3,85,25,"一 财务(白):");
	LODOP.ADD_PRINT_TEXT(474,307,85,25,"二 仓库(红):");
	print(isprint,tableIn);
}
//调拨
function allocation(obj,data,isprint,diaobo){
	LODOP.PRINT_INIT("调拨");
	LODOP.ADD_PRINT_TABLE(170,"4mm",713,297,diaobo);
	LODOP.ADD_PRINT_TEXT(41,216,311,27,"佛山市高尔顿家具有限公司");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",17);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(72,305,115,21,"调拨单");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",14);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	
	LODOP.ADD_PRINT_TEXT(146,23,90,20,"提出仓：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",14);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.ADD_PRINT_TEXT(146,113,125,20,obj.zd003OutWhName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",14);
	
	LODOP.ADD_PRINT_TEXT(146,244,89,20,"提入仓：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",14);
	LODOP.ADD_PRINT_TEXT(146,332,135,20,obj.zd004InWhName);
	
	var arr=obj.zd005OutDate.split('-');
	LODOP.SET_PRINT_STYLEA(0,"FontSize",14);
	LODOP.ADD_PRINT_TEXT(146,494,225,20,"日期："+arr[0]+"年"+arr[1]+'月'+arr[2]+'日');
	LODOP.SET_PRINT_STYLEA(0,"FontSize",14);
	LODOP.ADD_PRINT_TEXT(95,466,85,20,"调拨单号：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	LODOP.ADD_PRINT_TEXT(95,553,170,20,obj.zd001Code);//调拨单号
	LODOP.SET_PRINT_STYLEA(0,"FontSize",11);
	var j=0;
	for(var i=0;i<data.length;i++){
		j=i*26+206;
		LODOP.ADD_PRINT_TEXT(j,20,74,20,data[i].zd003Code);//编码
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(j,95,140,20,data[i].zd004Name);//名称
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(j,238,115,20,data[i].zd007Model);//型号
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(j,356,40,20,data[i].zd012Unit);//单位
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(j,402,70,20,data[i].zd019WhQuantity);//库存
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(j,471,75,20,data[i].zd019Quantity);//调拨数量
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	}
	
	LODOP.ADD_PRINT_TEXT(205,553,170,227,obj.zd008Remark);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.ADD_PRINT_TEXT(438,66,85,20,"制单人：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",14);
	LODOP.ADD_PRINT_TEXT(438,161,115,20,obj.zd007Aegnt);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",14);
	LODOP.ADD_PRINT_TEXT(438,383,85,20,"验收人：");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",14);
	LODOP.ADD_PRINT_TEXT(438,470,100,20,"");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",14);
	print(isprint,diaobo);

}
//其他出库
function otherOut(obj,data,isprint,table,total,now){
	var left=0; var hight=30;
		LODOP.PRINT_INITA(0,0+left,824,600,"其他出库");
		LODOP.ADD_PRINT_TABLE(140,2,"202.99mm","115.89mm",table);
		LODOP.ADD_PRINT_LINE(33,726,8,752,0,1);
		LODOP.ADD_PRINT_TEXT(23,737,25,20,total);
		LODOP.ADD_PRINT_TEXT(9,726,25,20,now);
		LODOP.ADD_PRINT_TEXT(14,211,354,35,"佛山市高尔顿家具有限公司");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",20);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(47,320,125,30,"其他出库单");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",16);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(47,561,45,25,"单号:");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(47,598,160,25,obj.zd001OutCode);
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(86,5,65,25,"供应商:");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(86,66,135,25,"");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(84,563,55,25,"仓库:");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(84,611,105,25,obj.zd004WhName);
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(84,306,75,25,"流水号:");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(85,377,155,25,obj.zd013RunningNumber);
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(117,306,70,25,"业务员:");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(117,373,140,25,"");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		var accountName=obj.zd011CustomerName.split("-");	
		LODOP.ADD_PRINT_TEXT(117,306,70,25,"业务员:");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(117,373,140,25,accountName[accountName.length-1]);
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(58,6,60,25,"日期:");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		var date=obj.zd010OtherDate.split('-');		 
		LODOP.ADD_PRINT_TEXT(58,53,150,25,date[0]+"年"+date[1]+"年"+date[2]+"日");
		LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(117,5,45,25,"客户:");
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(117,51,125,25,obj.zd011CustomerName);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(119,563,40,25,"备注:");
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		LODOP.ADD_PRINT_TEXT(119,602,165,25,obj.zd007Remark);
		LODOP.SET_PRINT_STYLEA(0,"Bold",1);
		var allmoney=0;
		for(var i=0;i<data.length;i++){
			LODOP.ADD_PRINT_TEXT(174+hight*i,2,85,30,obj.zd012PiCode);//pi单号
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(174+hight*i,87,40,30,data[i].id);//系列 
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(174+hight*i,127,135,30,data[i].zd002MaterialsName);//名称
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(174+hight*i,261,125,30,data[i].zd004MaterialsModel);//型号 
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(174+hight*i,385,90,30,data[i].zd003MaterialsSpec);//规格
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(174+hight*i,475,40,30,data[i].zd006Unit);//单位 
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			var out=parseFloat(data[i].zd007Quantity);
			LODOP.ADD_PRINT_TEXT(174+hight*i,515,40,30,data[i].zd007Quantity);//数量 
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(174+hight*i,555,55,30,data[i].zd009Price);//单价 
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			var outmoney=parseFloat(data[i].zd009Price)*out;
			LODOP.ADD_PRINT_TEXT(174+hight*i,606,64,30,outmoney);//合计
			allmoney=allmoney+outmoney;
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
			LODOP.ADD_PRINT_TEXT(176+hight*i,668,100,26,data[i].zd019MaterDecript);//描述
			LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		}
		LODOP.ADD_PRINT_TEXT(447,4,60,25,"制单人:");
		LODOP.ADD_PRINT_TEXT(447,62,115,25,obj.zd006Aegnt);
		LODOP.ADD_PRINT_TEXT(447,194,60,25,"送货人：");
		LODOP.ADD_PRINT_TEXT(447,253,110,25,"");
		LODOP.ADD_PRINT_TEXT(447,383,70,25,"收货人：");
		LODOP.ADD_PRINT_TEXT(447,453,100,25,"");
		LODOP.ADD_PRINT_TEXT(448,588,50,25,"合计：");
		LODOP.ADD_PRINT_TEXT(448,638,100,25,allmoney);
		LODOP.ADD_PRINT_TEXT(474,3,85,25,"一 财务(红):");
		LODOP.ADD_PRINT_TEXT(474,307,85,25,"二 仓库(白):");
		print(isprint,table);
}
//成品入库单
function prostoragein(obj,data,isprint,table,total,now){
	 var hight=30;
	LODOP.PRINT_INITA(0,0,824,600,"成品入库单");
	LODOP.ADD_PRINT_TABLE(140,1,"202.99mm","115.89mm",table);
	LODOP.ADD_PRINT_LINE(33,726,8,752,0,1);
	LODOP.ADD_PRINT_TEXT(23,737,25,20,total);
	LODOP.ADD_PRINT_TEXT(9,726,25,20,now);
	LODOP.ADD_PRINT_TEXT(14,211,354,35,"佛山市高尔顿家具有限公司");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",20);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,300,150,30,"成品入库单");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",16);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,570,45,25,"单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,607,160,25,obj.zd001InCode);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,5,65,25,"PI单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,66,135,25,obj.zd003PiCode);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,5,55,25,"仓库:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,53,105,25,obj.zd004WhName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,306,55,25,"客户:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,349,165,25,obj.zd012CustomerName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,305,65,25,"业务员:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,363,140,25,obj.zd015SalesMan);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	var date=obj.zd010OtherDate.split("-");
	LODOP.ADD_PRINT_TEXT(117,570,60,25,"日期:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,617,150,25,date[0]+"年"+date[1]+"月"+date[2]+"日");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	for(var i=0;i<data.length;i++){
		LODOP.ADD_PRINT_TEXT(174+hight*i,2,65,30,data[i].id);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,67,165,30,data[i].zd002MaterialsName);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,230,185,30,data[i].zd004MaterialsModel);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,412,125,30,data[i].zd015MaterialsSize);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,534,45,30,data[i].zd006Unit);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		var inq=parseFloat(data[i].zd007Quantity);
		LODOP.ADD_PRINT_TEXT(174+hight*i,579,65,30,inq);
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,641,125,30,data[i].zd014MaterialsDescription);
	}

	LODOP.ADD_PRINT_TEXT(447,4,60,25,"制单人:");
	LODOP.ADD_PRINT_TEXT(447,62,115,25,obj.zd006Aegnt);
	LODOP.ADD_PRINT_TEXT(447,194,60,25,"领料人：");
	LODOP.ADD_PRINT_TEXT(447,253,110,25,"");
	LODOP.ADD_PRINT_TEXT(447,383,70,25,"仓库主管：");
	LODOP.ADD_PRINT_TEXT(447,453,100,25,"");
	LODOP.ADD_PRINT_TEXT(448,588,50,25,"合计：");
	LODOP.ADD_PRINT_TEXT(448,638,100,25,"");
	LODOP.ADD_PRINT_TEXT(474,3,85,25,"一 财务(红):");
	LODOP.ADD_PRINT_TEXT(474,307,85,25,"二 仓库(白):");
	print(isprint,tableIn);
}
//采购入库打印
function purchaseware(obj,data,isprint,table,total,now){
	var left=0; var hight=30;
	LODOP.PRINT_INITA(0,0+left,824,600,"其他入库");
	LODOP.ADD_PRINT_TABLE(140,2,"202.99mm","115.89mm",table);
	LODOP.ADD_PRINT_LINE(33,726,8,752,0,1);
	LODOP.ADD_PRINT_TEXT(23,737,25,20,total);
	LODOP.ADD_PRINT_TEXT(9,726,25,20,now);
	LODOP.ADD_PRINT_TEXT(14,211,354,35,"佛山市高尔顿家具有限公司");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",20);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,320,125,30,"采购入库单");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",16);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,561,45,25,"单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,598,160,25,obj.zd003Code);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,5,65,25,"供应商:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,66,135,25,obj.zd008SupeName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,563,55,25,"仓库:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,611,105,25,obj.zd007WhName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,306,75,25,"送货单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(85,377,155,25,obj.zd017MaterialInCode);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,306,70,25,"业务员:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	var accname=obj.zd019AccountName.split("-");
	LODOP.ADD_PRINT_TEXT(117,373,140,25,accname[accname.length-1]);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(58,6,60,25,"日期:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	var date=obj.zd013Date.split("-");
	LODOP.ADD_PRINT_TEXT(58,53,150,25,date[0]+"年"+date[1]+"年"+date[2]+"日");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	for(var i=0;i<data.length;i++){
		LODOP.ADD_PRINT_TEXT(174+hight*i,2,85,30,obj.zd016PiCode);//pi单号
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,87,40,30,data[i].id);//系列 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,127,135,30,data[i].zd005Name);//名称
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,261,125,30,data[i].zd007Model);//型号 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,385,90,30,data[i].zd011Size);//规格
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,475,40,30,data[i].zd012Unit);//单位 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		var inq=parseFloat(data[i].zd018HsQuantity);
		LODOP.ADD_PRINT_TEXT(174+hight*i,515,40,30,inq);//数量 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,555,55,30,data[i].zd016Price);//单价 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,606,64,30,data[i].zd025SumMoney);//合计
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(176+hight*i,668,100,26,data[i].zd024Descript);//描述
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	}
	LODOP.ADD_PRINT_TEXT(447,4,60,25,"制单人:");
	LODOP.ADD_PRINT_TEXT(447,62,115,25,obj.zd011Atten);
	LODOP.ADD_PRINT_TEXT(447,194,60,25,"送货人：");
	LODOP.ADD_PRINT_TEXT(447,253,110,25,"");
	LODOP.ADD_PRINT_TEXT(447,383,70,25,"收货人：");
	LODOP.ADD_PRINT_TEXT(447,453,100,25,"");
	LODOP.ADD_PRINT_TEXT(448,588,50,25,"合计：");
	LODOP.ADD_PRINT_TEXT(448,638,100,25,obj.zd018TheSumMoney);
	LODOP.ADD_PRINT_TEXT(474,3,85,25,"一 财务(黄):");
	LODOP.ADD_PRINT_TEXT(474,307,85,25,"二 仓库(白):");
	LODOP.ADD_PRINT_TEXT(474,573,100,25,"三 供应商(红):");
	LODOP.ADD_PRINT_TEXT(117,5,45,25,"客户:");
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,51,125,25,obj.zd019AccountName);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(119,563,40,25,"备注:");
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(119,602,165,25,obj.zd014Remark);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	print(isprint,table);
}


//其他入库打印
function otherIn(obj,data,isprint,table,total,now){
	var left=0; var hight=30;
	LODOP.PRINT_INITA(0,0+left,824,600,"其他入库");
	LODOP.ADD_PRINT_TABLE(140,2,"202.99mm","115.89mm",table);
	LODOP.ADD_PRINT_LINE(33,726,8,752,0,1);
	LODOP.ADD_PRINT_TEXT(23,737,25,20,total);
	LODOP.ADD_PRINT_TEXT(9,726,25,20,now);
	LODOP.ADD_PRINT_TEXT(14,211,354,35,"佛山市高尔顿家具有限公司");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",20);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,320,125,30,"其他入库单");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",16);
	LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,561,45,25,"单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(47,598,160,25,obj.zd001InCode);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);	
	LODOP.ADD_PRINT_TEXT(86,5,65,25,"供应商:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(86,66,135,25,obj.zd011CustomerName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,563,55,25,"仓库:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,611,105,25,obj.zd004WhName);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(84,306,75,25,"送货单号:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(85,377,155,25,obj.zd012MaterialInCode);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	var accountName=obj.zd013AccountName.split("-");
	LODOP.ADD_PRINT_TEXT(117,306,70,25,"业务员:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,373,140,25,accountName[accountName.length-1]);
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(58,6,60,25,"日期:");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	var date=obj.zd010OtherDate.split("-");
	LODOP.ADD_PRINT_TEXT(58,53,150,25,date[0]+"年"+date[1]+"年"+date[2]+"日");
	LODOP.SET_PRINT_STYLEA(0,"FontSize",10);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	for(var i=0;i<data.length;i++){
		LODOP.ADD_PRINT_TEXT(174+hight*i,2,85,30,obj.zd005PiCode);//pi单号
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,87,40,30,data[i].id);//系列 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,127,135,30,data[i].zd002MaterialsName);//名称
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,261,125,30,data[i].zd004MaterialsModel);//型号 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,385,90,30,data[i].zd005MaterialsSize);//规格
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,475,40,30,data[i].zd006Unit);//单位 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,515,40,30,data[i].zd007Quantity);//数量 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,555,55,30,data[i].zd009Price);//单价 
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(174+hight*i,606,64,30,data[i].zd014SumMoney);//合计
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
		LODOP.ADD_PRINT_TEXT(176+hight*i,668,100,26,data[i].zd015MaterDecript);//描述
		LODOP.SET_PRINT_STYLEA(0,"Alignment",2);
	}
	LODOP.ADD_PRINT_TEXT(447,4,60,25,"制单人:");
	LODOP.ADD_PRINT_TEXT(447,62,115,25,obj.zd006Aegnt);
	LODOP.ADD_PRINT_TEXT(447,194,60,25,"送货人：");
	LODOP.ADD_PRINT_TEXT(447,253,110,25,"");
	LODOP.ADD_PRINT_TEXT(447,383,70,25,"收货人：");
	LODOP.ADD_PRINT_TEXT(447,453,100,25,"");
	LODOP.ADD_PRINT_TEXT(448,588,50,25,"合计：");
	LODOP.ADD_PRINT_TEXT(448,638,100,25,obj.zd013TheSumMoney);
	LODOP.ADD_PRINT_TEXT(474,3,85,25,"一 财务(黄):");
	LODOP.ADD_PRINT_TEXT(474,307,85,25,"二 仓库(白):");
	LODOP.ADD_PRINT_TEXT(474,573,100,25,"三 供应商(红):");
	LODOP.ADD_PRINT_TEXT(117,5,45,25,"客户:");
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(117,51,125,25,obj.zd013AccountName);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(119,563,40,25,"备注:");
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	LODOP.ADD_PRINT_TEXT(119,602,165,25,obj.zd007Remark);
	LODOP.SET_PRINT_STYLEA(0,"Bold",1);
	print(isprint,table);
}

function print(isprint,table){
	if(isprint){
		LODOP.PRINT_SETUP();//预览打印
		//直接打印  PRINT()
	}else{
		LODOP.PREVIEW();
	}
	LODOP.NEWPAGE();
	table="";
}
// 生产 入库
function tableIn(){
	var tableIn="<table   border='1' cellspacing='0' cellpadding='0'   >"+
		"<tr align='center' height='26'><td width='76'>成品系列</td><td  width='60'>业务员</td><td width='152'>客户</td>"+
		"<td  width='80'>品名</td><td width='76'>型号</td><td width='80'>尺寸</td><td width='36'>单位</td><td width='36'>数量</td>"+
		"<td width='118'>备注</td></tr>";
	for(var i=0;i<9;i++){
		tableIn=tableIn+"<tr height='26' ><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td></tr>";
	}
	tableIn=tableIn+"<tr height='26'><td colspan='9'></td></tr></table>";
	return tableIn;
}
//其他出库
function tableOut(){
	var tableOut="<table  width='695'  border='1' cellspacing='0' cellpadding='0'   >"+
	"<tr height='28.7' align='center' ><td width='80'>PI单号</td><td width='60'>编号</td><td  width='120'>物料名称</td><td  width='100'>规格型号</td ><td width='40'>单位</td><td  width='40'>数量</td><td>备注</td>";
	for(var i=0;i<9;i++){
		tableOut=tableOut+"<tr align='center' height='28.7'><td></td><td></td><td></td><td></td><td></td><td></td><td></td></tr>";
	}
	tableOut=tableOut+"<tr height='28.7'><td colspan='9'></td></tr></table>";
	return tableOut;
}

function diaobo(){
	//调拨
	var diaobo="<table width='709'  border='1' cellspacing='0' cellpadding='0'  >"+
				"<tr align='center' height='26'><td width='76'>编码</td><td width='140' >名称</td><td width='120'>型号</td>"+
				"<td width='40'>单位</td><td width='76'>库存数</td><td width='76'>调拨数量</td><td>备注</td></tr>"+
				"<tr height='26'><td></td><td></td><td></td><td></td><td></td><td></td><td rowspan='9'></td></tr>";
	for(var i=0;i<8;i++){
		diaobo=diaobo+"<tr height='26'><td></td><td></td><td></td><td></td><td></td><td></td></tr>";
	}
	return diaobo+"<tr height='26'><td colspan='7'></td></tr></table>";

}
//销售出库
function xiaoshou(){
	var xiaoshou="<table width='695'  border='1' cellspacing='0' cellpadding='0'   >"+
				"<tr align='center' height='26'><td width='76'>成品系列</td><td  width='60'>业务员</td><td width='120'>客户</td>"+
				"<td  width='80'>品名</td><td width='50'>型号</td><td width='60'>尺寸</td><td width='36'>单位</td><td width='40'>数量</td><td>备注</td></tr>";
	for(var i=0 ; i<9;i++){
		xiaoshou=xiaoshou+"<tr height='26' ><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td></tr>";
	}
	return xiaoshou+"<tr height='26'><td colspan='9'></td></tr></table>";
}
//领料出库
function  materialtable(){
	var materialout="<table  width='695'  border='1' cellspacing='0' cellpadding='0'   >"+
	"<tr height='28.7' align='center' ><td width='78'>库别</td><td width='80'>编号</td><td width='120'>物料名称</td><td  width='100'>规格型号</td><td width='40'>单位</td><td width='40'>数量</td><td>备注</td></tr>";
	for(var i=0;i<9;i++){
		materialout=materialout+"<tr align='center' height='28.7'><td></td><td></td><td></td><td></td><td></td><td></td><td></td></tr>";
	}
	return materialout+"<tr height='28.7'><td colspan='7'></td></tr></table>";
}
//反审 其他出库
function fsqitachuku(){
	var table="<table  border='1' cellspacing='0' cellpadding='0'   >"+
	"<tr height='28.7' align='center' ><td width='100'>PI单号</td><td width='100'>编号</td><td width='100'>物料名称</td>"+
	"<td width='100'>规格型号</td><td width='40'>单位</td><td width='70'>出库数量</td><td width='70'>反审数量</td><td>备注</td>";
	for(var i=0;i<9;i++){
		table=table+"<tr align='center' height='28.7'><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td></tr>";
	}
	return table+"<tr height='28.7'><td colspan='9'></td></tr></table>";
	
}

function paigong(){
	var paigong="<table  border='1px' cellspacing='0' cellpadding='0' ><tr align='center'  height='26.46px'>"+
	"<td width='70px'>产品名称</td><td width='130.38px' >型号</td><td width='70px' >尺寸</td>"+
	"<td width='70px' >工序</td><td width='40px' >数量</td><td width='50px' >单价</td>"+
	"<td width='90px' >备注</td></tr>";
	for(var i=0;i<7;i++){
		 paigong=paigong+"<tr height='26.46px'><td></td><td></td><td></td><td></td><td></td><td></td><td></td><td></td></tr>";
	}
	return paigong+"</table>";
}

function paigongcc(){
	var paigong="<table border='1px' cellspacing='0' cellpadding='0' ><tr align='center' height='26.46px'>"+
	"<td width='70px'>产品名称</td><td width='40px' >型号</td><td width='60px' >尺寸</td>"+
	"<td width='40px' >工序</td><td width='40px' >数量</td><td width='50px' >单价</td>"+
	"<td width='230px' >备注</td></tr>";
	for(var i=0;i<7;i++){
		 paigong=paigong+"<tr height='26.46px'><td></td><td></td><td></td><td></td><td></td><td></td><td></td></tr>";
	}
	return paigong+"</table>";
}
function checkBackTable(){
	var table="<table style='border: 1px solid black;border-style: solid;border-collapse: collapse'  >"+
				"<tr height='28.7' align='center' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>"+
				"<td width='120'style='border: 1px solid black;border-style: solid;border-collapse: collapse'>物料名称</td>"+
				"<td width='120' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>型号</td>"+
				"<td width='120' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>尺寸规格</td>"+
				"<td  width='100' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>颜色</td>"+
				"<td  width='100' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>材质</td>"+
				"<td width='40' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>单位</td>"+
				"<td width='50' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>原数量</td>"+
				"<td width='65' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>反审数量</td></tr>";
	var content="";
	for(var i=0;i<7;i++){
		content= content+"<tr height='28.7' align='center' style='border: 1px solid black;border-style: solid;border-collapse: collapse' >"+
				"<td width='120' style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				"<td width='120' style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				"<td width='120' style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				"<td  width='100' style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				"<td  width='100' style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				"<td width='40' style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				"<td width='50' style='border: 1px solid black;border-style: solid;border-collapse: collapse' ></td>"+
				"<td width='60' style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				"</tr>";
	}
	return table+content+"</table>";
}
function materialtable(){
	var table="<table border='1' width='760' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>"+
				"<tr align='center'height='30' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>"+
				  "<td width='80'style='border: 1px solid black;border-style: solid;border-collapse: collapse'>PI单号</td>"+
				 "<td width='40' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>系列</td>"+
				  "<td  width='130' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>名称</td>"+
				  "<td width='120' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>型号</td>"+
				  "<td width='90' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>规格</td>"+
				  "<td width='35' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>单位</td>"+
				  "<td width='35' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>数量</td>"+
				  "<td width='50' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>单价</td>"+
				  "<td width='60'>金额</td>"+
				  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'>描述</td>"+
				"</tr>";
	for(var i=0;i<9;i++){
		table=table+"<tr height='30'  align='center' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>"+
				  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
				"</tr>";
	}
	table=table+"<tr height='30'  align='center' style='border: 1px solid black;border-style: solid;border-collapse: collapse'> <td colspan='10' style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td></tr></table>";
	return table;
}
function productiontable(){
	var table="<table border='1' width='760' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>"+
				"<tr align='center'height='30' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>"+
				  "<td width='60' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>系列</td>"+
				  "<td width='160' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>名称</td>"+
				  "<td width='180' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>型号</td>"+
				  "<td width='120' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>规格</td>"+
				  "<td width='40' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>单位</td>"+
				  "<td width='60' style='border: 1px solid black;border-style: solid;border-collapse: collapse'>数量</td>"+
				  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'>描述</td>"+
				"</tr>";
	for(var i=0;i<9;i++){
		table=table+"<tr height='30' align='center'>"+
						  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
						  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
					      "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
						  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
						  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
						  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
						  "<td style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td>"+
					"</tr>";
	}
	table=table+"<tr height='30'  style='border: 1px solid black;border-style: solid;border-collapse: collapse'> <td colspan='7' style='border: 1px solid black;border-style: solid;border-collapse: collapse'></td></tr></table>";
	return table;
}